﻿using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using System.Threading.Tasks;

namespace ConsoleApp1
{
    class Program
    {
        static void Main(string[] args)
        {
            
            //Console.WriteLine("请输入数据");
            //int a = int.Parse(Console.ReadLine());
            //int b = int.Parse(Console.ReadLine());
            //xiushif( a , b);
            Console.WriteLine("请输入形状");
            string Shape = Console.ReadLine();
            xingzhuang(Shape);



        }
        public static void xingzhuang(string shape)
        {
            Shape shape1 = new Shape();
            Circle c1 = new Circle();
            Square square = new Square();
            switch (shape)
            {
                case "正方形":
                    Console.WriteLine("请输入边长");
                    double s = double.Parse(Console.ReadLine());
                    square.GetArea(s);
                    break;
                case "圆形":
                    Console.WriteLine("请输入半径");
                    double k = double.Parse(Console.ReadLine());
                    c1.GetArea(k );

                    break;
            }
        }
        public static void xiushif(int a,int b) {
            Calculate c = new Calculate();
            Class1 c1 = new Class1();
            Class2 c2 = new Class2();
            Class3 c3 = new Class3();
            Class4 c4 = new Class4();
            Console.WriteLine("请输入修饰符");
            string fu = Console.ReadLine();

            switch (fu)
            {
                case "+":
                    c1.DisplayResult(a,b);
                    break;
                case "-":
                    c4.DisplayResult(a, b);
                    break;
                case "*":
                    c2.DisplayResult(a, b);
                    break;
                case "/":
                    c3.DisplayResult(a, b);
                    break;


            }

        }
    }
}
